In the beginning of the second millennium B.C. Babylon became the centre of power in Mesopotamia. Hammurapi (1792-1750 B.C.) was one of the most important kings of the First Dynasty of Babylon. He is above all known for his law code (Codex Hammurapi). At the height of his power the Old Babylonian Empire extended as far as Sumer in the south and to Nineveh in the north. After the Old Babylonian times a dark period followed in the history of Mesopotamia. The conquest of Babylon in 1595 B.C. by the Hittite king Mursilis I ended the First Dynasty of Babylon. His allies, the Kassites from the Zagros Mountains, occupied Babylon without breaking the Babylonian traditions. Dur Kurigalzu became their capital. In 1157 B.C. the Kassite Dynasty was attacked from Elam (southwestern Iran) and came to an end.